import { rcaNumberFormat0 } from './common.js'
import { commonTableOption } from './common.js'
export const tableOption = {
  ...commonTableOption,
  height: 450,
  column: [{
    type: 'date',
    label: '日期范围',
    searchSpan: 12,
    width: 180,
    searchRange: true,
    search: true,
    format: 'yyyy-MM-dd',
    valueFormat: 'yyyy-MM-dd',
    prop: 'cleanTime',
    slot: true
  }, {
    type: 'input',
    type: 'select',
    search: true,
    label: '运营商',
    width: 180,
    props: {
      label: 'operatorsName',
      value: 'operators'
    },
    dicUrl: '/rca/swckclearemergencyreturnticket/listoperators',
    prop: 'operators',
    formatter: (row, value, label, column) => {
      if(value=='合计'){
        return '合计'
      }else{
        return value
      }
    },
  }, {
    type: 'select',
    label: '线路',
    prop: 'lineCode',
    width: 180,
    search: false,
    display: true,
    props: {
      label: 'name',
      value: 'code'
    },
    dicUrl: '/support/swparamline/dictsecondname',
    formatter: (row, value, label, column) => {
      if(value=='小计'){
        return '小计'
      }else{
        return value
      }
    },
  },
  {
    label: '未进ACC系统的交易',
    children: [
      {
        label: "误出站应急纸票",
        children: [
          {
            label: '误出站应急纸票',
            children: [
              {
                type: 'input',
                width:'150px',
                label: '回收金额',
                prop: 'emeRecycle',
                showSummary: true,
                precision: 7,
                formatter: (row, value, label, column) => {
                  return rcaNumberFormat0(value)
                },
              }, {
                type: 'input',
                width:'150px',
                label: '发售金额',
                prop: 'emeSale',
                showSummary: true,
                precision: 7,
                formatter: (row, value, label, column) => {
                  return rcaNumberFormat0(value)
                },
              }, {
                type: 'input',
                width:'150px',
                label: '清分及划账金额',
                prop: 'emeClear',
                showSummary: true,
                precision: 7,
                formatter: (row, value, label, column) => {
                  return rcaNumberFormat0(value)
                },
              }
            ]
          }
        ]
      },
      {
        label: '大客流应急纸票',
        children: [
          {
            label: '西安地铁大客流发售应急纸票',
            children: [
              {
                type: 'input',
                width:'150px',
                label: '发售金额',
                prop: 'streamXadtSale',
                showSummary: true,
                precision: 7,
                formatter: (row, value, label, column) => {
                  return rcaNumberFormat0(value)
                },
              }, {
                type: 'input',
                width:'150px',
                label: '回收金额',
                prop: 'streamXadtRecycle',
                showSummary: true,
                precision: 7,
                formatter: (row, value, label, column) => {
                  return rcaNumberFormat0(value)
                },
              }, {
                type: 'input',
                width:'150px',
                label: '清分及划账金额',
                prop: 'streamXadtClear',
                showSummary: true,
                precision: 7,
                formatter: (row, value, label, column) => {
                  return rcaNumberFormat0(value)
                },
              }
            ]
          },
          {
            label: '14号线机场段发售大客流应急纸票',
            children: [
              {
                type: 'input',
                width:'150px',
                label: '发售金额',
                prop: 'streamAirSale',
                showSummary: true,
                precision: 7,
                formatter: (row, value, label, column) => {
                  return rcaNumberFormat0(value)
                },
              }, {
                type: 'input',
                width:'150px',
                label: '回收金额',
                prop: 'streamAirRecycle',
                showSummary: true,
                precision: 7,
                formatter: (row, value, label, column) => {
                  return rcaNumberFormat0(value)
                },
              }, {
                type: 'input',
                width:'150px',
                label: '清分及划账金额',
                prop: 'streamAirClear',
                showSummary: true,
                precision: 7,
                formatter: (row, value, label, column) => {
                  return rcaNumberFormat0(value)
                },
              }
            ]
          },
          {
            label: '9号线大客流发售应急纸票',
            children: [
              {
                type: 'input',
                width:'150px',
                label: '发售金额',
                prop: 'streamXaztSale',
                showSummary: true,
                precision: 7,
                formatter: (row, value, label, column) => {
                  return rcaNumberFormat0(value)
                },
              }, {
                type: 'input',
                width:'150px',
                label: '回收金额',
                prop: 'streamXaztRecycle',
                showSummary: true,
                precision: 7,
                formatter: (row, value, label, column) => {
                  return rcaNumberFormat0(value)
                },
              }, {
                type: 'input',
                width:'150px',
                label: '清分及划账金额',
                prop: 'streamXaztClear',
                showSummary: true,
                precision: 7,
                formatter: (row, value, label, column) => {
                  return rcaNumberFormat0(value)
                },
              }
            ]
          }
        ]
      },
      {
        label: '正常情况下退票',
        children: [
          {
            label: '正常情况下退票（与14号线机场段）',
            children: [
              {
                type: 'input',
                width:'220px',
                label: '退款北客站（北广场）购买车票金额',
                prop: 'failNormalAirStationSale',
                showSummary: true,
                precision: 7,
                formatter: (row, value, label, column) => {
                  return rcaNumberFormat0(value)
                },
              }, {
                type: 'input',
                width:'150px',
                label: '清分及划账金额',
                prop: 'failNormalAirStationClear',
                showSummary: true,
                precision: 7,
                formatter: (row, value, label, column) => {
                  return rcaNumberFormat0(value)
                },
              }, {
                type: 'input',
                width:'180px',
                label: '退其他车站购买车票金额',
                prop: 'failNormalAirOtherstationSale',
                showSummary: true,
                precision: 7,
                formatter: (row, value, label, column) => {
                  return rcaNumberFormat0(value)
                },
              }, {
                type: 'input',
                width:'150px',
                label: '清分及划账金额',
                prop: 'failNormalAirOtherstationClear',
                showSummary: true,
                precision: 7,
                formatter: (row, value, label, column) => {
                  return rcaNumberFormat0(value)
                },
              }, {
                type: 'input',
                width:'150px',
                label: '合计清分及划账金额',
                prop: 'failNormalAirTotalClear',
                showSummary: true,
                precision: 7,
                formatter: (row, value, label, column) => {
                  return rcaNumberFormat0(value)
                },
              }
            ]
          },
          {
            label: '正常情况下退票（与9号线）',
            children: [
              {
                type: 'input',
                width:'180px',
                label: '退款纺织城购买车票金额',
                prop: 'failNormalXaztStationSale',
                showSummary: true,
                precision: 7,
                formatter: (row, value, label, column) => {
                  return rcaNumberFormat0(value)
                },
              }, {
                type: 'input',
                width:'150px',
                label: '清分及划账金额',
                prop: 'failNormalXaztStationClear',
                showSummary: true,
                precision: 7,
                formatter: (row, value, label, column) => {
                  return rcaNumberFormat0(value)
                },
              }, {
                type: 'input',
                width:'180px',
                label: '退其他车站购买车票金额',
                prop: 'failNormalXaztOtherstationSale',
                showSummary: true,
                precision: 7,
                formatter: (row, value, label, column) => {
                  return rcaNumberFormat0(value)
                },
              }, {
                type: 'input',
                width:'150px',
                label: '清分及划账金额',
                prop: 'failNormalXaztOtherstationClear',
                showSummary: true,
                precision: 7,
                formatter: (row, value, label, column) => {
                  return rcaNumberFormat0(value)
                },
              }, {
                type: 'input',
                width:'150px',
                label: '合计清分及划账金额',
                prop: 'failNormalXaztTotalClear',
                showSummary: true,
                precision: 7,
                formatter: (row, value, label, column) => {
                  return rcaNumberFormat0(value)
                },
              }
            ]
          }
        ]
      },
      {
        label: '特殊情况下退票',
        children: [
          {
            label: '西安地铁故障导致特殊退款',
            children: [
              {
                type: 'input',
                width:'150px',
                label: '退14号线机场段金额',
                prop: 'failSpeXadterrorSale',
                showSummary: true,
                precision: 7,
                formatter: (row, value, label, column) => {
                  return rcaNumberFormat0(value)
                },
              }, {
                type: 'input',
                width:'150px',
                label: '退9号线金额',
                prop: 'failSpeXadterrorSaleNine',
                showSummary: true,
                precision: 7,
                formatter: (row, value, label, column) => {
                  return rcaNumberFormat0(value)
                },
              }, {
                type: 'input',
                width:'150px',
                label: '合计退款金额',
                prop: 'failSpeXadterrorSaleSum',
                showSummary: true,
                precision: 7,
                formatter: (row, value, label, column) => {
                  return rcaNumberFormat0(value)
                },
              }, {
                type: 'input',
                width:'150px',
                label: '清分及划账金额',
                prop: 'failSpeXadterrorClearSum',
                showSummary: true,
                precision: 7,
                formatter: (row, value, label, column) => {
                  return rcaNumberFormat0(value)
                },
              }
            ]
          },
          {
            label: '14号线机场段故障导致特殊退款',
            children: [
              {
                type: 'input',
                width:'150px',
                label: '退款金额',
                prop: 'failSpeAirerrorSale',
                showSummary: true,
                precision: 7,
                formatter: (row, value, label, column) => {
                  return rcaNumberFormat0(value)
                },
              }, {
                type: 'input',
                width:'150px',
                label: '清分及划账金额',
                prop: 'failSpeAirerrorClear',
                showSummary: true,
                precision: 7,
                formatter: (row, value, label, column) => {
                  return rcaNumberFormat0(value)
                },
              }
            ]
          },
          {
            label: '9号线故障导致特殊退款',
            children: [
              {
                type: 'input',
                width:'150px',
                label: '退款金额',
                prop: 'failSpeXazterrorSale',
                showSummary: true,
                precision: 7,
                formatter: (row, value, label, column) => {
                  return rcaNumberFormat0(value)
                },
              }, {
                type: 'input',
                width:'150px',
                label: '清分及划账金额',
                prop: 'failSpeXazterrorClear',
                showSummary: true,
                precision: 7,
                formatter: (row, value, label, column) => {
                  return rcaNumberFormat0(value)
                },
              }
            ]
          }
        ]
      },
      {
        label: '合计',
        children: [
          {
            type: 'input',
            width:'150px',
            label: '清分及划账金额',
            prop: 'totalClear',
            showSummary: true,
            precision: 7,
            formatter: (row, value, label, column) => {
              return rcaNumberFormat0(value)
            },
          }
        ]
      }
    ]
  },
  ]
}
